$primaryColor: var(--color);

@mixin blockEach {
    // 通用模板(讨论/笔记)
    display: flex;
    border-bottom: 1px solid #EEEEEE;
    padding: 15px 0;
    position: relative;
    .pointer { cursor: pointer; }
    .block-left {
        img {
            width: 40px;
            height: 40px;
            border-radius: 50%;
        }
        margin-right: 10px;
    }
    .block-right {
        width: 100%;
        .top {
            min-height: 22px;
        }
        .name {
            height: 20px;
            font-size: 14px;
            font-weight: 400;
            line-height: 20px;
            color: #7F7F7F;
            span { margin-right: 5px; }
            &.flexable {
                display: flex;
            }
        }
        .content {
            margin-bottom: 4px;
            font-size: 16px;
            line-height: 23px;
            color: #333;
            word-break: break-all;
        }
        .bottom {
            color: #999;
            font-size: 12px;
            line-height: 16px;
            display: flex;
            // justify-content: space-between;
            position: relative;
        }
        .video {
            margin-left: 10px;
            .video-icon {
                width: 8px;
                height: 8px;
                vertical-align: baseline;
                margin-right: 5px;
                display: inline-block;
                background-size: 100% 100% !important;
                &.dark {
                    background: url('');
                }
            }
            .video-name {
                max-width: 100px;
                display: inline-block;
                vertical-align: bottom;
            }
        }
        .agree, .collect {
            font-size: 12px;
            color: #999;
            position: absolute;
            right: 5px;
            top: 0px;
            span {
                display: inline-block;
                vertical-align: middle;
            }
            .van-icon{
                font-size: 14px;
            }
            .agree-icon,  .collect-icon {
                width: 15px;
                height: 15px;
                display: inline-block;
                background-size: 100%;
                vertical-align: -3px;
                margin-right: 1px;
                cursor: pointer;
                background-image: url('');
            }
            .collect-icon {
                background-image: url('')
            }
            &.active {
                color: $primaryColor;
                .agree-icon {
                    background-image: url('');
                }
                .collect-icon {
                    background-image: url('')
                }
            }

        }

        // 回复列表
        .under-list {
            margin-top: 8px;
            background: #F6F6F6;
            padding-top: 10px;
            border-radius: 6px;
            .under-list-each {
                display: flex;
                justify-content: space-between;
                padding: 0 5px 10px 10px;
                .agree {
                    right: 0;
                }
                .left {
                    font-size: 14px;
                    width: 100%;
                    .bottom {
                        margin-top: 5px;
                    }
                    .time {
                        color: #999;
                        font-size: 12px;
                    }
                    .top {
                        word-break: break-all;
                        padding-right: 10px;
                        .bold {
                            font-weight: bold;
                        }
                        .content {
                            line-height: 24px;
                        }
                    }
                }
                .right {
                    color: #999;
                    font-size: 12px;
                }
            }
            .btn-more {
                border-top: 1px solid #eee;
                color: #7F7F7F;
                padding: 9px 0;
                font-size: 12px;
                text-align: center;
            }
        }
    }
    .block-btn {
        position: absolute;
        right: 0;
        bottom: 10px;
    }
}

@mixin fileWrap {
    display: flex;
    padding: 19px 15px;
    align-items: center;
    box-shadow: 0px 8px 30px 0px rgba(226, 233, 232, 0.47);
    border-radius: 6px;
    margin-bottom: 15px;
    .file-icon {
        // position: relative;
    }
    .file-content {
        margin-left: 5PX;
        width: 80%;
        .content-top, .content-bottom {
            display: flex;
            // justify-content: space-between;
        }
        .content-top {
            font-size: 14px;
            margin-bottom: 3px;
            .top-left {
                width: 540px;
                height: 20px;
                font-weight: bold;
                line-height: 20px;
            }
        }
        .content-bottom {
            font-size: 12px;
            color: #999999;
            line-height: 17px;
        }
    }
    .btn-more {
        margin-left: 30px;
        :deep(.el-icon-more){
            color: #999999;
        }
    }
}

@mixin bottomInpuBar {
    position: fixed;
    bottom: 0;
    width: 100%;
    padding: 0 15px 20px;
    border-top: 1PX solid #EEEEEE;
    background: #FFF;
    left: 50%;
    transform: translateX(-50%);
    :deep(.van-search) {
        padding-right: 0;
        padding-left: 0;
    }
}

// 课时学习状态
@mixin lessonStatus {
    position: absolute;
    width: 14px;
    height: 14px;
    background-size: 100% 100%;
    top: 16px;
    left: 16px;
    border: 1px solid #DDDDDD;
    border-radius: 50%;
    display: inline-block;
    vertical-align: -1px;
    &.full {
        &:before{
            content: '';
            position: absolute;
            width: 10px;
            height: 10px;
            border: 5px solid #1EA69D;
            border: 5px solid var(--color);
            border-radius: 50%;
            left: 1px;
            top: 1px;
        }
    }
    &.empty {
    }
    &.half {
        &:before{
            content: '';
            position: absolute;
            width: 0;
            height: 0;
            border: 5px solid #1EA69D;
            border: 5px solid var(--color);
            border-radius: 50%;
            left: 1px;
            top: 1px;
            border-left-color: transparent;
            border-top-color: transparent;
            transform: rotate(-45deg);
        }
    }
    &.line::after {
        position: absolute;
        content: ' ';
        left: 5px;
        top: 13px;
        height: 67px;
        width: 2PX;
        background-color: #DDDDDD;
        z-index: 1;
    }
}

// 自定义简单tabs
@mixin customTabs {
    .custom-tabs__bar {
        display: flex;
        padding-bottom: 20px;
        .custom-tab {
            width: 50%;
            color: #999999;
            font-size: 16px;
            text-align: center;
            font-weight: bold;
            position: relative;
            &.van-tab--active {
                color: #333333;
                &::after {
                    position: absolute;
                    width: 64px;
                    height: 6px;
                    background: $primaryColor;
                    opacity: 0.66;
                    bottom: 1px;
                    right: 50%;
                    margin-right: -32px;
                    content: ' ';
                }
            }
        }

    }
}

@mixin progressContent {
    padding: 18px 0 0 10px;
    .each {
        border-left: 3px solid #EEEEEE;
        margin-bottom: 0;
        display: flex;
        padding-bottom: 20px;
		margin-left: 4px;
        &.last {
            padding-bottom: 0px;
            margin-bottom: 20px;
        }
        .tip {
            font-size: 12px;
            color: #999999;
            line-height: 17px;
        }
        .content {
            margin-top: 3px;
            font-size: 14px;
        }
        i {
            width: 7px;
            height: 7px;
            font-size: 14px;
            color: #DDDDDD;
            background: #ffffff;
            border-radius: 50%;
            border: 2PX solid $primaryColor;
            margin-right: 26px;
            margin-top: 7px;
            position: relative;
            right: 5px;
            top: 0;
        }
    }
}